<%-- 
    Document   : alta_paciente
    Created on : 21/08/2014, 07:22:00 PM
    Author     : Jorge
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <link rel="shortcut icon" href="../../imagenes/logonutre-t.png"/>
        <link rel="stylesheet" href="../css/nutriologo.css">
        <title>Pacientes</title>

    </head>
    <body>
    <center>
        <%
            String usuario = "";
            String perfil = "";
            String id = "";
            HttpSession sesionX = request.getSession();
            if (sesionX.getAttribute("perfil") == null) {
        %>
        <jsp:forward page="../../regresarr.jsp">
            <jsp:param name="error" value="es obligatorio identificarse"/>
        </jsp:forward>
        <%
        } else {
            if (sesionX.getAttribute("perfil").equals("nutriologo")) {
                usuario = (String) sesionX.getAttribute("usuario");
                perfil = (String) sesionX.getAttribute("perfil");
                id = (String) sesionX.getAttribute("id");%>
        <div class="regresa"><a href="../nutriologo.jsp"><img src="../../imagenes/regresar.png" alt="NUTRE-T" class="regresa"/></a></div>
        <div class="Cabezera">Bienvenido <%out.print(usuario);%> <div class="Cabezera-rigth"><a href='salir.jsp'>Cerrar Secion</a></div> </div>
        <%
        } else {
        %>
        <jsp:forward page="../../regresar.jsp">
            <jsp:param name="error" value="es obligatorio identificarse"/>
        </jsp:forward>
        <%
                }
            }
        %>
        <table>
            <tr>
                <td width="80%">
                    <form method="post" action="alta.jsp">
                        <div class="div_paciente">
                            <table >
                                <tr>
                                    <td><span>Nombre</span></td>
                                    <td><input type="text" name="nombre" autocomplete="off" class="campo" required></td>
                                </tr>
                                <tr>
                                    <td><span>Apellidos</span></td>
                                    <td><input type="text" name="apeidos" autocomplete="off"  class="campo" required></td>
                                </tr>
                                <tr>
                                    <td><span>Direccion</span></td>
                                    <td><input type="text" name="direccion" autocomplete="off"  class="campo " required></td>
                                </tr>
                                <tr>
                                    <td><span>Correo</span></td>
                                    <td><input type="email" name="correo" autocomplete="off"  class="campo" required></td>
                                </tr>
                                <tr>
                                    <td><span>Edad</span></td>
                                    <td><input type="number" name="edad" autocomplete="off"  class="campo" required></td>
                                </tr>
                                <tr>
                                    <td><span>Sexo</span></td>
                                    <td>M:<input type="radio" name="sexo" value="mujer"> H:<input type="radio" name="sexo" value="hombre"></td>
                                </tr>
                                <tr>
                                    <td><span>Peso Actual</span></td>
                                    <td><input type="number" name="peso" required autocomplete="off"  class="campo" ></td>
                                </tr>
                                <tr>
                                    <td><span>Altura</span></td>
                                    <td><input type="text" name="altura" autocomplete="off" required  class="campo" ></td>
                                </tr>
                            </table>


                        </div>
                        <div class="div_paciente2">
                            <center><h2> Enfermedades </h2></center>
                            <table>
                                <tr>
                                    <td><span>Diabetes</span></td>
                                    <td><span>Cardiovasculares</span></td>
                                    <td><span>Anemia</span></td>
                                    <td><span>Epilepsia</span></td>
                                    <td><span>Tuberculosis</span></td>
                                </tr>
                                <tr>
                                    <td><input type="checkbox" value="si" name="diabetes"/></td>
                                    <td><input type="checkbox" value="si" name="cardiovasculares"/></td>
                                    <td><input type="checkbox" value="si" name="anemia"/></td>
                                    <td><input type="checkbox" value="si" name="epilepsia"/></td>
                                    <td><input type="checkbox" value="si" name="tuberculosis"/></td>
                                </tr>
                                <tr>
                                    <td><span>Hipertension</span></td>
                                    <td><span>Cancer</span></td>
                                    <td><span>Sida</span></td>
                                    <td><span>Reumatismo</span></td>
                                    <td><span>Hemofilia</span></td>
                                </tr>
                                <tr>
                                    <td><input type="checkbox" value="si" name="hipertension"/></td>
                                    <td><input type="checkbox" value="si" name="cancer"/></td>
                                    <td><input type="checkbox" value="si" name="sida"/></td>
                                    <td><input type="checkbox" value="si" name="reumatismo"/></td>
                                    <td><input type="checkbox" value="si" name="hemofilia"/></td>
                                </tr>
                            </table>
                        </div>
                        <center> <input type="submit" value="Enviar" /></center>
                    </form>
                </td>
            </tr>
        </table>
    </center>

</html>
